<template>
    <div class="child">
<h4>我是child组件</h4>
    </div>
</template>

<script setup>
import { ref } from 'vue'
let sum =ref(123)
async function asyncFunction() {
    return new Promise((resolve, reject) => {
        setTimeout(() => {
            resolve(sum.value)
        }, 2000);
    })
}

await asyncFunction()
</script>

<style scoped>
.child{background-color: bisque;padding: 10px;}
</style>